-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support MySQL GRANT SENSITIVE_VARIABLES_OBSERVER #4412
base: master
Are you sure you want to change the base?
Conversation
@mike-lischke Is this change correct to the Oracle grammar? I just updated the grammar to the lastest from the vscode extension. #4408 |
This PR should be rejected. It adds a dynamic privilege to the grammar. The The upstream fix is also wrong btw. @kgalieva. And, very important, syntax which is supported only starting at a specific MySQL version should be guarded using a semantic predicate. You can see that everywhere in the MySQL grammar. |
Side note: this PR is not for the Oracle grammar, but the one from Positive Technologies. I'm not sure this repository should keep multiple MySQL grammars. |
Sorry, I see that now. I only saw that a test was modified over in the Oracle grammar, and it parses fine.
I agree. It might be time to archive the PT grammar, or just remove it. |
@teverett @KvanTTT What do you think? Shall we remove the PT MySQL grammar, in favor of the Oracle grammar? I know the PT grammar also supports MySQL 5.6 and 5.7, but these versions are EOL already and the PT grammar is only partially correct. If people really want support for these versions, they can download an earlier version of the current Oracle grammar from https://github.com/mysql/mysql-workbench/blob/8.0/library/parsers/grammars/. |
I have a conflict of interests here, as my grammar would prevail, so maybe someone else is the better choice to drive this process. This PR here as well as the one you mentioned @KvanTTT are both wrong (I explained that above). All I can do here is to suggest to remove the PT grammar, because it is not correct. It doesn't matter that someone still files PRs for it (it shows only the grammar needs changes to be correct). What happens instead it that PRs like this and #4383 add things that don't belong in this grammar. It's a MySQL grammar, not a TokuDB or Azure grammar. So with every such PR the grammar gets more and more incorrect, not to mention that it is way behind the actual MySQL time line (we are already working on 9.x). |
I have no concerns with keeping the PT grammar. If it's wrong, perhaps it could be corrected? |
Well, but I think it matters. I have no objection regarding removing, but please create an issue regarding the topic to notify users explicetly and get more other opinions. Unfortunately, legacy is not fun, but it's an important part of community support. |
Hi @KvanTTT, thanks for tagging me in this discussion. I would like to highlight that Debezium has been using the Positive Technologies MySQL grammar since at least 2017. To keep up with the evolving MySQL syntax, our maintainers (and community members) actively contribute updates to the upstream PT grammar whenever we make any changes in our grammar.
In the past, we haven’t received feedback on our PRs regarding these concerns. We didn’t anticipate that the TokuDB or Azure grammar PRs would be merged here, but since they were, we contributed to ensure support for all MySQL grammar variations. That said, we are open to refining our contributions and providing specific semantic predicates where needed.
That would be helpful. I will need to discuss these changes with my team. |
Please note: it was not my intention to use this issue to decide about the future of the PT grammar. All I wanted was to get a general yes/no input from important people in this process. Of course there must be a good deprecation path etc. to phase out the grammar. Ideally one of the owners of it should take the stab and start this process. |
Adding support for
GRANT SENSITIVE_VARIABLES_OBSERVER
for MySQLhttps://dev.mysql.com/doc/refman/8.4/en/privileges-provided.html